package com.andreiamariei.tema6;

import javax.persistence.EntityManagerFactory;
import javax.persistence.Persistence;

public class PersistenceProvider {

	private static EntityManagerFactory emf; 
	
	public static synchronized EntityManagerFactory getEntityManagerFactory() {
		if (emf == null) {
			emf = Persistence.createEntityManagerFactory("MovieManagement");
		}
		return emf;
	}
}
